//
// CBlendShape.java
// Copyright (C) 2010  "Naush" <naush _ hotmail _ fr>
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>./* ----------------------------------------------------------------------------







package org.ryzom.nel.threed;

import org.ryzom.nel.misc.IStream;

public class CBlendShape {
  private long swigCPtr;
  protected boolean swigCMemOwn;

  public CBlendShape(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  public static long getCPtr(CBlendShape obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if (swigCPtr != 0) {
      if (swigCMemOwn) {
        swigCMemOwn = false;
        nel3dJNI.delete_CBlendShape(swigCPtr);
      }
      swigCPtr = 0;
    }
  }

  public void setName(String value) {
    nel3dJNI.CBlendShape_Name_set(swigCPtr, this, value);
  }

  public String getName() {
    return nel3dJNI.CBlendShape_Name_get(swigCPtr, this);
  }

  public void setDeltaPos(Vector_CVector value) {
    nel3dJNI.CBlendShape_deltaPos_set(swigCPtr, this, Vector_CVector.getCPtr(value), value);
  }

  public Vector_CVector getDeltaPos() {
    long cPtr = nel3dJNI.CBlendShape_deltaPos_get(swigCPtr, this);
    return (cPtr == 0) ? null : new Vector_CVector(cPtr, false);
  }

  public void setDeltaNorm(Vector_CVector value) {
    nel3dJNI.CBlendShape_deltaNorm_set(swigCPtr, this, Vector_CVector.getCPtr(value), value);
  }

  public Vector_CVector getDeltaNorm() {
    long cPtr = nel3dJNI.CBlendShape_deltaNorm_get(swigCPtr, this);
    return (cPtr == 0) ? null : new Vector_CVector(cPtr, false);
  }

  public void setDeltaTgSpace(Vector_CVector value) {
    nel3dJNI.CBlendShape_deltaTgSpace_set(swigCPtr, this, Vector_CVector.getCPtr(value), value);
  }

  public Vector_CVector getDeltaTgSpace() {
    long cPtr = nel3dJNI.CBlendShape_deltaTgSpace_get(swigCPtr, this);
    return (cPtr == 0) ? null : new Vector_CVector(cPtr, false);
  }

  public void setDeltaUV(SWIGTYPE_p_std__vectorT_NLMISC__CUV_t value) {
    nel3dJNI.CBlendShape_deltaUV_set(swigCPtr, this, SWIGTYPE_p_std__vectorT_NLMISC__CUV_t.getCPtr(value));
  }

  public SWIGTYPE_p_std__vectorT_NLMISC__CUV_t getDeltaUV() {
    long cPtr = nel3dJNI.CBlendShape_deltaUV_get(swigCPtr, this);
    return (cPtr == 0) ? null : new SWIGTYPE_p_std__vectorT_NLMISC__CUV_t(cPtr, false);
  }

  public void setDeltaCol(SWIGTYPE_p_std__vectorT_NLMISC__CRGBAF_t value) {
    nel3dJNI.CBlendShape_deltaCol_set(swigCPtr, this, SWIGTYPE_p_std__vectorT_NLMISC__CRGBAF_t.getCPtr(value));
  }

  public SWIGTYPE_p_std__vectorT_NLMISC__CRGBAF_t getDeltaCol() {
    long cPtr = nel3dJNI.CBlendShape_deltaCol_get(swigCPtr, this);
    return (cPtr == 0) ? null : new SWIGTYPE_p_std__vectorT_NLMISC__CRGBAF_t(cPtr, false);
  }

  public void setVertRefs(Vector_uint16 value) {
    nel3dJNI.CBlendShape_VertRefs_set(swigCPtr, this, Vector_uint16.getCPtr(value), value);
  }

  public Vector_uint16 getVertRefs() {
    long cPtr = nel3dJNI.CBlendShape_VertRefs_get(swigCPtr, this);
    return (cPtr == 0) ? null : new Vector_uint16(cPtr, false);
  }

  public void serial(IStream f) {
    nel3dJNI.CBlendShape_serial(swigCPtr, this, IStream.getCPtr(f), f);
  }

  public CBlendShape() {
    this(nel3dJNI.new_CBlendShape(), true);
  }

}
